import { UPDATEPAGECHOOSEJOBAREA } from '../types/pagechoosejobarea'
import { handleActions } from 'redux-actions'

const Schema = {
  showEmpty: false,
  requestOverFirst: false,
  networkerror: false,
  breaklocation: false,
  havenoshopbyshare: false,
  workArea: {
    cityName: '上海',
    cityCode: 12,
    choosedCityList: []
  },
  areaList: []
}

export default handleActions(
  {
    [UPDATEPAGECHOOSEJOBAREA](state, action) {
      return {
        ...state,
        ...action.payload
      }
    }
  },
  Schema
)
